home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 2: Applications / Linux Cubed Series 2 - Applications.iso / editors / emacs / xemacs / xemacs-1.006 / xemacs-1 / lib / xemacs-19.13 / info / lispref.info-23 < prev    next >
Encoding:
GNU Info File  |  1995-09-01  |  50.4 KB  |  1,183 lines

  1. This is Info file ../../info/lispref.info, produced by Makeinfo-1.63
  2. from the input file lispref.texi.
  3.  
  4.    Edition History:
  5.  
  6.    GNU Emacs Lisp Reference Manual Second Edition (v2.01), May 1993 GNU
  7. Emacs Lisp Reference Manual Further Revised (v2.02), August 1993 Lucid
  8. Emacs Lisp Reference Manual (for 19.10) First Edition, March 1994
  9. XEmacs Lisp Programmer's Manual (for 19.12) Second Edition, April 1995
  10. GNU Emacs Lisp Reference Manual v2.4, June 1995 XEmacs Lisp
  11. Programmer's Manual (for 19.13) Third Edition, July 1995
  12.  
  13.    Copyright (C) 1990, 1991, 1992, 1993, 1994, 1995 Free Software
  14. Foundation, Inc.  Copyright (C) 1994, 1995 Sun Microsystems, Inc.
  15. Copyright (C) 1995 Amdahl Corporation.  Copyright (C) 1995 Ben Wing.
  16.  
  17.    Permission is granted to make and distribute verbatim copies of this
  18. manual provided the copyright notice and this permission notice are
  19. preserved on all copies.
  20.  
  21.    Permission is granted to copy and distribute modified versions of
  22. this manual under the conditions for verbatim copying, provided that the
  23. entire resulting derived work is distributed under the terms of a
  24. permission notice identical to this one.
  25.  
  26.    Permission is granted to copy and distribute translations of this
  27. manual into another language, under the above conditions for modified
  28. versions, except that this permission notice may be stated in a
  29. translation approved by the Foundation.
  30.  
  31.    Permission is granted to copy and distribute modified versions of
  32. this manual under the conditions for verbatim copying, provided also
  33. that the section entitled "GNU General Public License" is included
  34. exactly as in the original, and provided that the entire resulting
  35. derived work is distributed under the terms of a permission notice
  36. identical to this one.
  37.  
  38.    Permission is granted to copy and distribute translations of this
  39. manual into another language, under the above conditions for modified
  40. versions, except that the section entitled "GNU General Public License"
  41. may be included in a translation approved by the Free Software
  42. Foundation instead of in the original English.
  43.  
  44. 
  45. File: lispref.info,  Node: Cyclic Window Ordering,  Next: Buffers and Windows,  Prev: Selecting Windows,  Up: Windows
  46.  
  47. Cyclic Ordering of Windows
  48. ==========================
  49.  
  50.    When you use the command `C-x o' (`other-window') to select the next
  51. window, it moves through all the windows on the screen in a specific
  52. cyclic order.  For any given configuration of windows, this order never
  53. varies.  It is called the "cyclic ordering of windows".
  54.  
  55.    This ordering generally goes from top to bottom, and from left to
  56. right.  But it may go down first or go right first, depending on the
  57. order in which the windows were split.
  58.  
  59.    If the first split was vertical (into windows one above each other),
  60. and then the subwindows were split horizontally, then the ordering is
  61. left to right in the top of the frame, and then left to right in the
  62. next lower part of the frame, and so on.  If the first split was
  63. horizontal, the ordering is top to bottom in the left part, and so on.
  64. In general, within each set of siblings at any level in the window tree,
  65. the order is left to right, or top to bottom.
  66.  
  67.  - Function: next-window &optional WINDOW MINIBUF ALL-FRAMES
  68.      This function returns the window following WINDOW in the cyclic
  69.      ordering of windows.  This is the window that `C-x o' would select
  70.      if typed when WINDOW is selected.  If WINDOW is the only window
  71.      visible, then this function returns WINDOW.  If omitted, WINDOW
  72.      defaults to the selected window.
  73.  
  74.      The value of the argument MINIBUF determines whether the
  75.      minibuffer is included in the window order.  Normally, when
  76.      MINIBUF is `nil', the minibuffer is included if it is currently
  77.      active; this is the behavior of `C-x o'.  (The minibuffer window
  78.      is active while the minibuffer is in use.  *Note Minibuffers::.)
  79.  
  80.      If MINIBUF is `t', then the cyclic ordering includes the
  81.      minibuffer window even if it is not active.
  82.  
  83.      If MINIBUF is neither `t' nor `nil', then the minibuffer window is
  84.      not included even if it is active.
  85.  
  86.      The argument ALL-FRAMES specifies which frames to consider.  Here
  87.      are the possible values and their meanings:
  88.  
  89.     `nil'
  90.           Consider all the windows in WINDOW's frame, plus the
  91.           minibuffer used by that frame even if it lies in some other
  92.           frame.
  93.  
  94.     `t'
  95.           Consider all windows in all existing frames.
  96.  
  97.     `visible'
  98.           Consider all windows in all visible frames.  (To get useful
  99.           results, you must ensure WINDOW is in a visible frame.)
  100.  
  101.     0
  102.           Consider all windows in all visible or iconified frames.
  103.  
  104.     anything else
  105.           Consider precisely the windows in WINDOW's frame, and no
  106.           others.
  107.  
  108.      This example assumes there are two windows, both displaying the
  109.      buffer `windows.texi':
  110.  
  111.           (selected-window)
  112.                => #<window 56 on windows.texi>
  113.           (next-window (selected-window))
  114.                => #<window 52 on windows.texi>
  115.           (next-window (next-window (selected-window)))
  116.                => #<window 56 on windows.texi>
  117.  
  118.  - Function: previous-window &optional WINDOW MINIBUF ALL-FRAMES
  119.      This function returns the window preceding WINDOW in the cyclic
  120.      ordering of windows.  The other arguments specify which windows to
  121.      include in the cycle, as in `next-window'.
  122.  
  123.  - Command: other-window COUNT &optional FRAME
  124.      This function selects the COUNTth following window in the cyclic
  125.      order.  If count is negative, then it selects the -COUNTth
  126.      preceding window.  It returns `nil'.
  127.  
  128.      In an interactive call, COUNT is the numeric prefix argument.
  129.  
  130.      The argument FRAME controls which set of windows are considered.
  131.         * If it is `nil' or omitted, then windows on the selected frame
  132.           are considered.
  133.  
  134.         * If it is a frame, then windows on that frame are considered.
  135.  
  136.         * If it is `t', then windows on all frames that currently exist
  137.           (including invisible and iconified frames) are considered.
  138.  
  139.         * If it is the symbol `visible', then windows on all visible
  140.           frames are considered.
  141.  
  142.         * If it is the number 0, then windows on all visible and
  143.           iconified frames are considered.
  144.  
  145.         * If it is any other value, then the behavior is undefined.
  146.  
  147.  - Function: walk-windows PROC &optional MINIBUF ALL-FRAMES
  148.      This function cycles through all windows, calling `proc' once for
  149.      each window with the window as its sole argument.
  150.  
  151.      The optional arguments MINIBUF and ALL-FRAMES specify the set of
  152.      windows to include in the scan.  See `next-window', above, for
  153.      details.
  154.  
  155. 
  156. File: lispref.info,  Node: Buffers and Windows,  Next: Displaying Buffers,  Prev: Cyclic Window Ordering,  Up: Windows
  157.  
  158. Buffers and Windows
  159. ===================
  160.  
  161.    This section describes low-level functions to examine windows or to
  162. display buffers in windows in a precisely controlled fashion.
  163.  
  164.    *Note Displaying Buffers::, for related functions that find a window
  165. to use and specify a buffer for it.  The functions described there are
  166. easier to use than these, but they employ heuristics in choosing or
  167. creating a window; use these functions when you need complete control.
  168.  
  169.  - Function: set-window-buffer WINDOW BUFFER-OR-NAME
  170.      This function makes WINDOW display BUFFER-OR-NAME as its contents.
  171.      It returns `nil'.
  172.  
  173.           (set-window-buffer (selected-window) "foo")
  174.                => nil
  175.  
  176.  - Function: window-buffer &optional WINDOW
  177.      This function returns the buffer that WINDOW is displaying.  If
  178.      WINDOW is omitted, this function returns the buffer for the
  179.      selected window.
  180.  
  181.           (window-buffer)
  182.                => #<buffer windows.texi>
  183.  
  184.  - Function: get-buffer-window BUFFER-OR-NAME &optional FRAME
  185.      This function returns a window currently displaying
  186.      BUFFER-OR-NAME, or `nil' if there is none.  If there are several
  187.      such windows, then the function returns the first one in the
  188.      cyclic ordering of windows, starting from the selected window.
  189.      *Note Cyclic Window Ordering::.
  190.  
  191.      The argument ALL-FRAMES controls which windows to consider.
  192.  
  193.         * If it is `nil', consider windows on the selected frame.
  194.  
  195.         * If it is `t', consider windows on all frames.
  196.  
  197.         * If it is `visible', consider windows on all visible frames.
  198.  
  199.         * If it is 0, consider windows on all visible or iconified
  200.           frames.
  201.  
  202.         * If it is a frame, consider windows on that frame.
  203.  
  204. 
  205. File: lispref.info,  Node: Displaying Buffers,  Next: Choosing Window,  Prev: Buffers and Windows,  Up: Windows
  206.  
  207. Displaying Buffers in Windows
  208. =============================
  209.  
  210.    In this section we describe convenient functions that choose a window
  211. automatically and use it to display a specified buffer.  These functions
  212. can also split an existing window in certain circumstances.  We also
  213. describe variables that parameterize the heuristics used for choosing a
  214. window.
  215.  
  216.    *Note Buffers and Windows::, for low-level functions that give you
  217. more precise control.
  218.  
  219.    Do not use the functions in this section in order to make a buffer
  220. current so that a Lisp program can access or modify it; they are too
  221. drastic for that purpose, since they change the display of buffers in
  222. windows, which is gratuitous and will surprise the user.  Instead, use
  223. `set-buffer' (*note Current Buffer::.) and `save-excursion' (*note
  224. Excursions::.), which designate buffers as current for programmed
  225. access without affecting the display of buffers in windows.
  226.  
  227.  - Command: switch-to-buffer BUFFER-OR-NAME &optional NORECORD
  228.      This function makes BUFFER-OR-NAME the current buffer, and also
  229.      displays the buffer in the selected window.  This means that a
  230.      human can see the buffer and subsequent keyboard commands will
  231.      apply to it.  Contrast this with `set-buffer', which makes
  232.      BUFFER-OR-NAME the current buffer but does not display it in the
  233.      selected window.  *Note Current Buffer::.
  234.  
  235.      If BUFFER-OR-NAME does not identify an existing buffer, then a new
  236.      buffer by that name is created.  The major mode for the new buffer
  237.      is set according to the variable `default-major-mode'.  *Note Auto
  238.      Major Mode::.
  239.  
  240.      Normally the specified buffer is put at the front of the buffer
  241.      list.  This affects the operation of `other-buffer'.  However, if
  242.      NORECORD is non-`nil', this is not done.  *Note The Buffer List::.
  243.  
  244.      The `switch-to-buffer' function is often used interactively, as
  245.      the binding of `C-x b'.  It is also used frequently in programs.
  246.      It always returns `nil'.
  247.  
  248.  - Command: switch-to-buffer-other-window BUFFER-OR-NAME
  249.      This function makes BUFFER-OR-NAME the current buffer and displays
  250.      it in a window not currently selected.  It then selects that
  251.      window.  The handling of the buffer is the same as in
  252.      `switch-to-buffer'.
  253.  
  254.      The currently selected window is absolutely never used to do the
  255.      job.  If it is the only window, then it is split to make a
  256.      distinct window for this purpose.  If the selected window is
  257.      already displaying the buffer, then it continues to do so, but
  258.      another window is nonetheless found to display it in as well.
  259.  
  260.  - Function: pop-to-buffer BUFFER-OR-NAME &optional OTHER-WINDOW
  261.           ON-FRAME
  262.      This function makes BUFFER-OR-NAME the current buffer and switches
  263.      to it in some window, preferably not the window previously
  264.      selected.  The "popped-to" window becomes the selected window
  265.      within its frame.
  266.  
  267.      If the variable `pop-up-windows' is non-`nil', windows may be
  268.      split to create a new window that is different from the original
  269.      window.  For details, see *Note Choosing Window::.
  270.  
  271.      If OTHER-WINDOW is non-`nil', `pop-to-buffer' finds or creates
  272.      another window even if BUFFER-OR-NAME is already visible in the
  273.      selected window.  Thus BUFFER-OR-NAME could end up displayed in
  274.      two windows.  On the other hand, if BUFFER-OR-NAME is already
  275.      displayed in the selected window and OTHER-WINDOW is `nil', then
  276.      the selected window is considered sufficient display for
  277.      BUFFER-OR-NAME, so that nothing needs to be done.
  278.  
  279.      All the variables that affect `display-buffer' affect
  280.      `pop-to-buffer' as well.  *Note Choosing Window::.
  281.  
  282.      If BUFFER-OR-NAME is a string that does not name an existing
  283.      buffer, a buffer by that name is created.  The major mode for the
  284.      new buffer is set according to the variable `default-major-mode'.
  285.      *Note Auto Major Mode::.
  286.  
  287.      If ON-FRAME is non-`nil', it is the frame to pop to this buffer on.
  288.  
  289.      An example use of this function is found at the end of *Note
  290.      Filter Functions::.
  291.  
  292.  - Command: replace-buffer-in-windows BUFFER
  293.      This function replaces BUFFER with some other buffer in all
  294.      windows displaying it.  The other buffer used is chosen with
  295.      `other-buffer'.  In the usual applications of this function, you
  296.      don't care which other buffer is used; you just want to make sure
  297.      that BUFFER is no longer displayed.
  298.  
  299.      This function returns `nil'.
  300.  
  301. 
  302. File: lispref.info,  Node: Choosing Window,  Next: Window Point,  Prev: Displaying Buffers,  Up: Windows
  303.  
  304. Choosing a Window for Display
  305. =============================
  306.  
  307.    This section describes the basic facility that chooses a window to
  308. display a buffer in--`display-buffer'.  All the higher-level functions
  309. and commands use this subroutine.  Here we describe how to use
  310. `display-buffer' and how to customize it.
  311.  
  312.  - Command: display-buffer BUFFER-OR-NAME &optional NOT-THIS-WINDOW
  313.      This command makes BUFFER-OR-NAME appear in some window, like
  314.      `pop-to-buffer', but it does not select that window and does not
  315.      make the buffer current.  The identity of the selected window is
  316.      unaltered by this function.
  317.  
  318.      If NOT-THIS-WINDOW is non-`nil', it means to display the specified
  319.      buffer in a window other than the selected one, even if it is
  320.      already on display in the selected window.  This can cause the
  321.      buffer to appear in two windows at once.  Otherwise, if
  322.      BUFFER-OR-NAME is already being displayed in any window, that is
  323.      good enough, so this function does nothing.
  324.  
  325.      `display-buffer' returns the window chosen to display
  326.      BUFFER-OR-NAME.
  327.  
  328.      Precisely how `display-buffer' finds or creates a window depends on
  329.      the variables described below.
  330.  
  331.    A window can be marked as "dedicated" to a particular buffer.  Then
  332. XEmacs will not automatically change which buffer appears in the
  333. window, such as `display-buffer' might normally do.
  334.  
  335.  - Function: window-dedicated-p WINDOW
  336.      This function returns WINDOW's dedicated object, usually `t' or
  337.      `nil'.
  338.  
  339.  - Function: set-window-buffer-dedicated WINDOW BUFFER
  340.      This function makes WINDOW display BUFFER and be dedicated to that
  341.      buffer.  Then XEmacs will not automatically change which buffer
  342.      appears in WINDOW.  If BUFFER is `nil', this function makes WINDOW
  343.      not be dedicated (but doesn't change which buffer appears in it
  344.      currently).
  345.  
  346.  - User Option: pop-up-windows
  347.      This variable controls whether `display-buffer' makes new windows.
  348.      If it is non-`nil' and there is only one window, then that window
  349.      is split.  If it is `nil', then `display-buffer' does not split
  350.      the single window, but uses it whole.
  351.  
  352.  - User Option: split-height-threshold
  353.      This variable determines when `display-buffer' may split a window,
  354.      if there are multiple windows.  `display-buffer' always splits the
  355.      largest window if it has at least this many lines.  If the largest
  356.      window is not this tall, it is split only if it is the sole window
  357.      and `pop-up-windows' is non-`nil'.
  358.  
  359.  - User Option: pop-up-frames
  360.      This variable controls whether `display-buffer' makes new frames.
  361.      If it is non-`nil', `display-buffer' looks for an existing window
  362.      already displaying the desired buffer, on any visible frame.  If
  363.      it finds one, it returns that window.  Otherwise it makes a new
  364.      frame.  The variables `pop-up-windows' and
  365.      `split-height-threshold' do not matter if `pop-up-frames' is
  366.      non-`nil'.
  367.  
  368.      If `pop-up-frames' is `nil', then `display-buffer' either splits a
  369.      window or reuses one.
  370.  
  371.      *Note Frames::, for more information.
  372.  
  373.  - Variable: pop-up-frame-function
  374.      This variable specifies how to make a new frame if `pop-up-frames'
  375.      is non-`nil'.
  376.  
  377.      Its value should be a function of no arguments.  When
  378.      `display-buffer' makes a new frame, it does so by calling that
  379.      function, which should return a frame.  The default value of the
  380.      variable is a function that creates a frame using parameters from
  381.      `pop-up-frame-alist'.
  382.  
  383.  - Variable: pop-up-frame-alist
  384.      This variable holds an alist specifying frame parameters used when
  385.      `display-buffer' makes a new frame.  *Note Frame Parameters::, for
  386.      more information about frame parameters.
  387.  
  388.  - Variable: special-display-buffer-names
  389.      A list of buffer names for buffers that should be displayed
  390.      specially.  If the buffer's name is in this list, `display-buffer'
  391.      handles the buffer specially.
  392.  
  393.      By default, special display means to give the buffer a dedicated
  394.      frame.
  395.  
  396.      If an element is a list, instead of a string, then the CAR of the
  397.      list is the buffer name, and the rest of the list says how to
  398.      create the frame.  There are two possibilities for the rest of the
  399.      list.  It can be an alist, specifying frame parameters, or it can
  400.      contain a function and arguments to give to it.  (The function's
  401.      first argument is always the buffer to be displayed; the arguments
  402.      from the list come after that.)
  403.  
  404.  - Variable: special-display-regexps
  405.      A list of regular expressions that specify buffers that should be
  406.      displayed specially.  If the buffer's name matches any of the
  407.      regular expressions in this list, `display-buffer' handles the
  408.      buffer specially.
  409.  
  410.      By default, special display means to give the buffer a dedicated
  411.      frame.
  412.  
  413.      If an element is a list, instead of a string, then the CAR of the
  414.      list is the regular expression, and the rest of the list says how
  415.      to create the frame.  See above, under
  416.      `special-display-buffer-names'.
  417.  
  418.  - Variable: special-display-function
  419.      This variable holds the function to call to display a buffer
  420.      specially.  It receives the buffer as an argument, and should
  421.      return the window in which it is displayed.
  422.  
  423.      The default value of this variable is
  424.      `special-display-popup-frame'.
  425.  
  426.  - Function: special-display-popup-frame BUFFER
  427.      This function makes BUFFER visible in a frame of its own.  If
  428.      BUFFER is already displayed in a window in some frame, it makes
  429.      the frame visible and raises it, to use that window.  Otherwise, it
  430.      creates a frame that will be dedicated to BUFFER.
  431.  
  432.      This function uses an existing window displaying BUFFER whether or
  433.      not it is in a frame of its own; but if you set up the above
  434.      variables in your init file, before BUFFER was created, then
  435.      presumably the window was previously made by this function.
  436.  
  437.  - User Option: special-display-frame-alist
  438.      This variable holds frame parameters for
  439.      `special-display-popup-frame' to use when it creates a frame.
  440.  
  441.  - Variable: same-window-buffer-names
  442.      A list of buffer names for buffers that should be displayed in the
  443.      selected window.  If the buffer's name is in this list,
  444.      `display-buffer' handles the buffer by switching to it in the
  445.      selected window.
  446.  
  447.  - Variable: same-window-regexps
  448.      A list of regular expressions that specify buffers that should be
  449.      displayed in the selected window.  If the buffer's name matches
  450.      any of the regular expressions in this list, `display-buffer'
  451.      handles the buffer by switching to it in the selected window.
  452.  
  453.  - Variable: display-buffer-function
  454.      This variable is the most flexible way to customize the behavior of
  455.      `display-buffer'.  If it is non-`nil', it should be a function
  456.      that `display-buffer' calls to do the work.  The function should
  457.      accept two arguments, the same two arguments that `display-buffer'
  458.      received.  It should choose or create a window, display the
  459.      specified buffer, and then return the window.
  460.  
  461.      This hook takes precedence over all the other options and hooks
  462.      described above.
  463.  
  464.    A window can be marked as "dedicated" to its buffer.  Then
  465. `display-buffer' does not try to use that window.
  466.  
  467.  - Function: window-dedicated-p WINDOW
  468.      This function returns `t' if WINDOW is marked as dedicated;
  469.      otherwise `nil'.
  470.  
  471.  - Function: set-window-dedicated-p WINDOW FLAG
  472.      This function marks WINDOW as dedicated if FLAG is non-`nil', and
  473.      nondedicated otherwise.
  474.  
  475. 
  476. File: lispref.info,  Node: Window Point,  Next: Window Start,  Prev: Choosing Window,  Up: Windows
  477.  
  478. Windows and Point
  479. =================
  480.  
  481.    Each window has its own value of point, independent of the value of
  482. point in other windows displaying the same buffer.  This makes it useful
  483. to have multiple windows showing one buffer.
  484.  
  485.    * The window point is established when a window is first created; it
  486.      is initialized from the buffer's point, or from the window point
  487.      of another window opened on the buffer if such a window exists.
  488.  
  489.    * Selecting a window sets the value of point in its buffer to the
  490.      window's value of point.  Conversely, deselecting a window sets
  491.      the window's value of point from that of the buffer.  Thus, when
  492.      you switch between windows that display a given buffer, the point
  493.      value for the selected window is in effect in the buffer, while
  494.      the point values for the other windows are stored in those windows.
  495.  
  496.    * As long as the selected window displays the current buffer, the
  497.      window's point and the buffer's point always move together; they
  498.      remain equal.
  499.  
  500.    * *Note Positions::, for more details on buffer positions.
  501.  
  502.    As far as the user is concerned, point is where the cursor is, and
  503. when the user switches to another buffer, the cursor jumps to the
  504. position of point in that buffer.
  505.  
  506.  - Function: window-point WINDOW
  507.      This function returns the current position of point in WINDOW.
  508.      For a nonselected window, this is the value point would have (in
  509.      that window's buffer) if that window were selected.
  510.  
  511.      When WINDOW is the selected window and its buffer is also the
  512.      current buffer, the value returned is the same as point in that
  513.      buffer.
  514.  
  515.      Strictly speaking, it would be more correct to return the
  516.      "top-level" value of point, outside of any `save-excursion' forms.
  517.      But that value is hard to find.
  518.  
  519.  - Function: set-window-point WINDOW POSITION
  520.      This function positions point in WINDOW at position POSITION in
  521.      WINDOW's buffer.
  522.  
  523. 
  524. File: lispref.info,  Node: Window Start,  Next: Vertical Scrolling,  Prev: Window Point,  Up: Windows
  525.  
  526. The Window Start Position
  527. =========================
  528.  
  529.    Each window contains a marker used to keep track of a buffer position
  530. that specifies where in the buffer display should start.  This position
  531. is called the "display-start" position of the window (or just the
  532. "start").  The character after this position is the one that appears at
  533. the upper left corner of the window.  It is usually, but not
  534. inevitably, at the beginning of a text line.
  535.  
  536.  - Function: window-start &optional WINDOW
  537.      This function returns the display-start position of window WINDOW.
  538.      If WINDOW is `nil', the selected window is used.  For example,
  539.  
  540.           (window-start)
  541.                => 7058
  542.  
  543.      When you create a window, or display a different buffer in it, the
  544.      display-start position is set to a display-start position recently
  545.      used for the same buffer, or 1 if the buffer doesn't have any.
  546.  
  547.      For a realistic example, see the description of `count-lines' in
  548.      *Note Text Lines::.
  549.  
  550.  - Function: window-end &optional WINDOW
  551.      This function returns the position of the end of the display in
  552.      window WINDOW.  If WINDOW is `nil', the selected window is used.
  553.  
  554.      Simply changing the buffer text or moving point does not update the
  555.      value that `window-end' returns.  The value is updated only when
  556.      Emacs redisplays and redisplay actually finishes.
  557.  
  558.      If the last redisplay of WINDOW was preempted, and did not finish,
  559.      Emacs does not know the position of the end of display in that
  560.      window.  In that case, this function returns a value that is not
  561.      correct.  In a future version, `window-end' will return `nil' in
  562.      that case.
  563.  
  564.  - Function: set-window-start WINDOW POSITION &optional NOFORCE
  565.      This function sets the display-start position of WINDOW to
  566.      POSITION in WINDOW's buffer.  It returns POSITION.
  567.  
  568.      The display routines insist that the position of point be visible
  569.      when a buffer is displayed.  Normally, they change the
  570.      display-start position (that is, scroll the window) whenever
  571.      necessary to make point visible.  However, if you specify the
  572.      start position with this function using `nil' for NOFORCE, it
  573.      means you want display to start at POSITION even if that would put
  574.      the location of point off the screen.  If this does place point
  575.      off screen, the display routines move point to the left margin on
  576.      the middle line in the window.
  577.  
  578.      For example, if point is 1 and you set the start of the window
  579.      to 2, then point would be "above" the top of the window.  The
  580.      display routines will automatically move point if it is still 1
  581.      when redisplay occurs.  Here is an example:
  582.  
  583.           ;; Here is what `foo' looks like before executing
  584.           ;;   the `set-window-start' expression.
  585.           
  586.           ---------- Buffer: foo ----------
  587.           -!-This is the contents of buffer foo.
  588.           2
  589.           3
  590.           4
  591.           5
  592.           6
  593.           ---------- Buffer: foo ----------
  594.           
  595.           (set-window-start
  596.            (selected-window)
  597.            (1+ (window-start)))
  598.           => 2
  599.           
  600.           ;; Here is what `foo' looks like after executing
  601.           ;;   the `set-window-start' expression.
  602.           ---------- Buffer: foo ----------
  603.           his is the contents of buffer foo.
  604.           2
  605.           3
  606.           -!-4
  607.           5
  608.           6
  609.           ---------- Buffer: foo ----------
  610.  
  611.      If NOFORCE is non-`nil', and POSITION would place point off screen
  612.      at the next redisplay, then redisplay computes a new window-start
  613.      position that works well with point, and thus POSITION is not used.
  614.  
  615.  - Function: pos-visible-in-window-p &optional POSITION WINDOW
  616.      This function returns `t' if POSITION is within the range of text
  617.      currently visible on the screen in WINDOW.  It returns `nil' if
  618.      POSITION is scrolled vertically out of view.  The argument
  619.      POSITION defaults to the current position of point; WINDOW, to the
  620.      selected window.  Here is an example:
  621.  
  622.           (or (pos-visible-in-window-p
  623.                (point) (selected-window))
  624.               (recenter 0))
  625.  
  626.      The `pos-visible-in-window-p' function considers only vertical
  627.      scrolling.  If POSITION is out of view only because WINDOW has
  628.      been scrolled horizontally, `pos-visible-in-window-p' returns `t'.
  629.      *Note Horizontal Scrolling::.
  630.  
  631. 
  632. File: lispref.info,  Node: Vertical Scrolling,  Next: Horizontal Scrolling,  Prev: Window Start,  Up: Windows
  633.  
  634. Vertical Scrolling
  635. ==================
  636.  
  637.    Vertical scrolling means moving the text up or down in a window.  It
  638. works by changing the value of the window's display-start location.  It
  639. may also change the value of `window-point' to keep it on the screen.
  640.  
  641.    In the commands `scroll-up' and `scroll-down', the directions "up"
  642. and "down" refer to the motion of the text in the buffer at which you
  643. are looking through the window.  Imagine that the text is written on a
  644. long roll of paper and that the scrolling commands move the paper up
  645. and down.  Thus, if you are looking at text in the middle of a buffer
  646. and repeatedly call `scroll-down', you will eventually see the
  647. beginning of the buffer.
  648.  
  649.    Some people have urged that the opposite convention be used: they
  650. imagine that the window moves over text that remains in place.  Then
  651. "down" commands would take you to the end of the buffer.  This view is
  652. more consistent with the actual relationship between windows and the
  653. text in the buffer, but it is less like what the user sees.  The
  654. position of a window on the terminal does not move, and short scrolling
  655. commands clearly move the text up or down on the screen.  We have chosen
  656. names that fit the user's point of view.
  657.  
  658.    The scrolling functions (aside from `scroll-other-window') have
  659. unpredictable results if the current buffer is different from the buffer
  660. that is displayed in the selected window.  *Note Current Buffer::.
  661.  
  662.  - Command: scroll-up &optional COUNT
  663.      This function scrolls the text in the selected window upward COUNT
  664.      lines.  If COUNT is negative, scrolling is actually downward.
  665.  
  666.      If COUNT is `nil' (or omitted), then the length of scroll is
  667.      `next-screen-context-lines' lines less than the usable height of
  668.      the window (not counting its modeline).
  669.  
  670.      `scroll-up' returns `nil'.
  671.  
  672.  - Command: scroll-down &optional COUNT
  673.      This function scrolls the text in the selected window downward
  674.      COUNT lines.  If COUNT is negative, scrolling is actually upward.
  675.  
  676.      If COUNT is omitted or `nil', then the length of the scroll is
  677.      `next-screen-context-lines' lines less than the usable height of
  678.      the window (not counting its mode line).
  679.  
  680.      `scroll-down' returns `nil'.
  681.  
  682.  - Command: scroll-other-window &optional COUNT
  683.      This function scrolls the text in another window upward COUNT
  684.      lines.  Negative values of COUNT, or `nil', are handled as in
  685.      `scroll-up'.
  686.  
  687.      You can specify a buffer to scroll with the variable
  688.      `other-window-scroll-buffer'.  When the selected window is the
  689.      minibuffer, the next window is normally the one at the top left
  690.      corner.  You can specify a different window to scroll with the
  691.      variable `minibuffer-scroll-window'.  This variable has no effect
  692.      when any other window is selected.  *Note Minibuffer Misc::.
  693.  
  694.      When the minibuffer is active, it is the next window if the
  695.      selected window is the one at the bottom right corner.  In this
  696.      case, `scroll-other-window' attempts to scroll the minibuffer.  If
  697.      the minibuffer contains just one line, it has nowhere to scroll
  698.      to, so the line reappears after the echo area momentarily displays
  699.      the message "Beginning of buffer".
  700.  
  701.  - Variable: other-window-scroll-buffer
  702.      If this variable is non-`nil', it tells `scroll-other-window'
  703.      which buffer to scroll.
  704.  
  705.  - User Option: scroll-step
  706.      This variable controls how scrolling is done automatically when
  707.      point moves off the screen.  If the value is zero, then redisplay
  708.      scrolls the text to center point vertically in the window.  If the
  709.      value is a positive integer N, then redisplay brings point back on
  710.      screen by scrolling N lines in either direction, if possible;
  711.      otherwise, it centers point.  The default value is zero.
  712.  
  713.  - User Option: next-screen-context-lines
  714.      The value of this variable is the number of lines of continuity to
  715.      retain when scrolling by full screens.  For example, `scroll-up'
  716.      with an argument of `nil' scrolls so that this many lines at the
  717.      bottom of the window appear instead at the top.  The default value
  718.      is `2'.
  719.  
  720.  - Command: recenter &optional COUNT
  721.      This function scrolls the selected window to put the text where
  722.      point is located at a specified vertical position within the
  723.      window.
  724.  
  725.      If COUNT is a nonnegative number, it puts the line containing
  726.      point COUNT lines down from the top of the window.  If COUNT is a
  727.      negative number, then it counts upward from the bottom of the
  728.      window, so that -1 stands for the last usable line in the window.
  729.      If COUNT is a non-`nil' list, then it stands for the line in the
  730.      middle of the window.
  731.  
  732.      If COUNT is `nil', `recenter' puts the line containing point in
  733.      the middle of the window, then clears and redisplays the entire
  734.      selected frame.
  735.  
  736.      When `recenter' is called interactively, COUNT is the raw prefix
  737.      argument.  Thus, typing `C-u' as the prefix sets the COUNT to a
  738.      non-`nil' list, while typing `C-u 4' sets COUNT to 4, which
  739.      positions the current line four lines from the top.
  740.  
  741.      With an argument of zero, `recenter' positions the current line at
  742.      the top of the window.  This action is so handy that some people
  743.      make a separate key binding to do this.  For example,
  744.  
  745.           (defun line-to-top-of-window ()
  746.             "Scroll current line to top of window.
  747.           Replaces three keystroke sequence C-u 0 C-l."
  748.             (interactive)
  749.             (recenter 0))
  750.           
  751.           (global-set-key [kp-multiply] 'line-to-top-of-window)
  752.  
  753. 
  754. File: lispref.info,  Node: Horizontal Scrolling,  Next: Size of Window,  Prev: Vertical Scrolling,  Up: Windows
  755.  
  756. Horizontal Scrolling
  757. ====================
  758.  
  759.    Because we read English first from top to bottom and second from left
  760. to right, horizontal scrolling is not like vertical scrolling.  Vertical
  761. scrolling involves selection of a contiguous portion of text to display.
  762. Horizontal scrolling causes part of each line to go off screen.  The
  763. amount of horizontal scrolling is therefore specified as a number of
  764. columns rather than as a position in the buffer.  It has nothing to do
  765. with the display-start position returned by `window-start'.
  766.  
  767.    Usually, no horizontal scrolling is in effect; then the leftmost
  768. column is at the left edge of the window.  In this state, scrolling to
  769. the right is meaningless, since there is no data to the left of the
  770. screen to be revealed by it; so this is not allowed.  Scrolling to the
  771. left is allowed; it scrolls the first columns of text off the edge of
  772. the window and can reveal additional columns on the right that were
  773. truncated before.  Once a window has a nonzero amount of leftward
  774. horizontal scrolling, you can scroll it back to the right, but only so
  775. far as to reduce the net horizontal scroll to zero.  There is no limit
  776. to how far left you can scroll, but eventually all the text will
  777. disappear off the left edge.
  778.  
  779.  - Command: scroll-left COUNT
  780.      This function scrolls the selected window COUNT columns to the
  781.      left (or to the right if COUNT is negative).  The return value is
  782.      the total amount of leftward horizontal scrolling in effect after
  783.      the change--just like the value returned by `window-hscroll'
  784.      (below).
  785.  
  786.  - Command: scroll-right COUNT
  787.      This function scrolls the selected window COUNT columns to the
  788.      right (or to the left if COUNT is negative).  The return value is
  789.      the total amount of leftward horizontal scrolling in effect after
  790.      the change--just like the value returned by `window-hscroll'
  791.      (below).
  792.  
  793.      Once you scroll a window as far right as it can go, back to its
  794.      normal position where the total leftward scrolling is zero,
  795.      attempts to scroll any farther right have no effect.
  796.  
  797.  - Function: window-hscroll &optional WINDOW
  798.      This function returns the total leftward horizontal scrolling of
  799.      WINDOW--the number of columns by which the text in WINDOW is
  800.      scrolled left past the left margin.
  801.  
  802.      The value is never negative.  It is zero when no horizontal
  803.      scrolling has been done in WINDOW (which is usually the case).
  804.  
  805.      If WINDOW is `nil', the selected window is used.
  806.  
  807.           (window-hscroll)
  808.                => 0
  809.           (scroll-left 5)
  810.                => 5
  811.           (window-hscroll)
  812.                => 5
  813.  
  814.  - Function: set-window-hscroll WINDOW COLUMNS
  815.      This function sets the number of columns from the left margin that
  816.      WINDOW is scrolled to the value of COLUMNS.  The argument COLUMNS
  817.      should be zero or positive; if not, it is taken as zero.
  818.  
  819.      The value returned is COLUMNS.
  820.  
  821.           (set-window-hscroll (selected-window) 10)
  822.                => 10
  823.  
  824.    Here is how you can determine whether a given position POSITION is
  825. off the screen due to horizontal scrolling:
  826.  
  827.      (defun hscroll-on-screen (window position)
  828.        (save-excursion
  829.          (goto-char position)
  830.          (and
  831.           (>= (- (current-column) (window-hscroll window)) 0)
  832.           (< (- (current-column) (window-hscroll window))
  833.              (window-width window)))))
  834.  
  835. 
  836. File: lispref.info,  Node: Size of Window,  Next: Position of Window,  Prev: Horizontal Scrolling,  Up: Windows
  837.  
  838. The Size of a Window
  839. ====================
  840.  
  841.    An Emacs window is rectangular, and its size information consists of
  842. the height (in lines or pixels) and the width (in character positions
  843. or pixels).  The modeline is included in the height.  The pixel width
  844. and height values include scrollbars and margins, while the
  845. line/character-position values do not.
  846.  
  847.    Note that the height in lines, and the width in characters, are
  848. determined by dividing the corresponding pixel value by the height or
  849. width of the default font in that window (if this is a variable-width
  850. font, the average width is used).  The resulting values may or may not
  851. represent the actual number of lines in the window, or the actual number
  852. of character positions in any particular line, esp. if there are pixmaps
  853. or various different fonts in the window.
  854.  
  855.    The following functions return size information about a window:
  856.  
  857.  - Function: window-height &optional WINDOW
  858.      This function returns the number of lines in WINDOW, including its
  859.      modeline but not including the horizontal scrollbar, if any (this
  860.      is different from `window-pixel-height').  If WINDOW is `nil', the
  861.      function uses the selected window.
  862.  
  863.           (window-height)
  864.                => 40
  865.           (split-window-vertically)
  866.                => #<window on "windows.texi" 0x679b>
  867.           (window-height)
  868.                => 20
  869.  
  870.  - Function: window-width &optional WINDOW
  871.      This function returns the number of columns in WINDOW, not
  872.      including any left margin, right margin, or vertical scrollbar
  873.      (this is different from `window-pixel-width').  If WINDOW is
  874.      `nil', the function uses the selected window.
  875.  
  876.           (window-width)
  877.                => 80
  878.           (window-height)
  879.                => 40
  880.           (split-window-horizontally)
  881.                => #<window on "windows.texi" 0x7538>
  882.           (window-width)
  883.                => 39
  884.  
  885.    Note that after splitting the window into two side-by-side windows,
  886. the width of each window is less the half the width of the original
  887. window because a vertical scrollbar appeared between the windows,
  888. occupying two columns worth of space.  Also, the height shrunk by one
  889. because horizontal scrollbars appeared that weren't there before.
  890. (Horizontal scrollbars appear only when lines are truncated, not when
  891. they wrap.  This is usually the case for horizontally split windows but
  892. not for full-frame windows.  You can change this using the variables
  893. `truncate-lines' and `truncate-partial-width-windows'.)
  894.  
  895.  - Function: window-pixel-height &optional WINDOW
  896.      This function returns the height of WINDOW in pixels, including
  897.      its modeline and horizontal scrollbar, if any.  If WINDOW is
  898.      `nil', the function uses the selected window.
  899.  
  900.           (window-pixel-height)
  901.                => 600
  902.           (split-window-vertically)
  903.                => #<window on "windows.texi" 0x68a6>
  904.           (window-pixel-height)
  905.                => 300
  906.  
  907.  - Function: window-pixel-width &optional WINDOW
  908.      This function returns the width of WINDOW in pixels, including any
  909.      left margin, right margin, or vertical scrollbar that may be
  910.      displayed alongside it.  If WINDOW is `nil', the function uses the
  911.      selected window.
  912.  
  913.           (window-pixel-width)
  914.                => 735
  915.           (window-pixel-height)
  916.                => 600
  917.           (split-window-horizontally)
  918.                => #<window on "windows.texi" 0x7538>
  919.           (window-pixel-width)
  920.                => 367
  921.           (window-pixel-height)
  922.                => 600
  923.  
  924. 
  925. File: lispref.info,  Node: Position of Window,  Next: Resizing Windows,  Prev: Size of Window,  Up: Windows
  926.  
  927. The Position of a Window
  928. ========================
  929.  
  930.    XEmacs provides functions to determine the absolute location of
  931. windows within a frame, and the relative location of a window in
  932. comparison to other windows in the same frame.
  933.  
  934.  - Function: window-pixel-edges &optional WINDOW
  935.      This function returns a list of the pixel edge coordinates of
  936.      WINDOW.  If WINDOW is `nil', the selected window is used.
  937.  
  938.      The order of the list is `(LEFT TOP RIGHT BOTTOM)', all elements
  939.      relative to 0, 0 at the top left corner of the frame.  The element
  940.      RIGHT of the value is one more than the rightmost pixel used by
  941.      WINDOW (including any left margin, right margin, or vertical
  942.      scrollbar displayed alongside it), and BOTTOM is one more than the
  943.      bottommost pixel used by WINDOW (including any modeline or
  944.      horizontal scrollbar displayed above or below it).  The frame area
  945.      does not include any frame menubars or toolbars that may be
  946.      displayed; thus, for example, if there is only one window on the
  947.      frame, the values for LEFT and TOP will always be 0.
  948.  
  949.      If WINDOW is at the upper left corner of its frame, RIGHT and
  950.      BOTTOM are the same as the values returned by
  951.      `(window-pixel-width)' and `(window-pixel-height)' respectively,
  952.      and TOP and BOTTOM are zero.
  953.  
  954.    There is no longer a function `window-edges' because it does not
  955. make sense in a world with variable-width and variable-height lines, as
  956. are allowed in XEmacs.
  957.  
  958.  - Function: window-highest-p WINDOW
  959.      This function returns non-`nil' if WINDOW is along the top of its
  960.      frame.
  961.  
  962.  - Function: window-lowest-p WINDOW
  963.      This function returns non-`nil' if WINDOW is along the bottom of
  964.      its frame.
  965.  
  966. 
  967. File: lispref.info,  Node: Resizing Windows,  Next: Window Configurations,  Prev: Position of Window,  Up: Windows
  968.  
  969. Changing the Size of a Window
  970. =============================
  971.  
  972.    The window size functions fall into two classes: high-level commands
  973. that change the size of windows and low-level functions that access
  974. window size.  XEmacs does not permit overlapping windows or gaps between
  975. windows, so resizing one window affects other windows.
  976.  
  977.  - Command: enlarge-window SIZE &optional HORIZONTAL
  978.      This function makes the selected window SIZE lines taller,
  979.      stealing lines from neighboring windows.  It takes the lines from
  980.      one window at a time until that window is used up, then takes from
  981.      another.  If a window from which lines are stolen shrinks below
  982.      `window-min-height' lines, that window disappears.
  983.  
  984.      If HORIZONTAL is non-`nil', this function makes WINDOW wider by
  985.      SIZE columns, stealing columns instead of lines.  If a window from
  986.      which columns are stolen shrinks below `window-min-width' columns,
  987.      that window disappears.
  988.  
  989.      If the requested size would exceed that of the window's frame,
  990.      then the function makes the window occupy the entire height (or
  991.      width) of the frame.
  992.  
  993.      If SIZE is negative, this function shrinks the window by -SIZE
  994.      lines or columns.  If that makes the window smaller than the
  995.      minimum size (`window-min-height' and `window-min-width'),
  996.      `enlarge-window' deletes the window.
  997.  
  998.      `enlarge-window' returns `nil'.
  999.  
  1000.  - Command: enlarge-window-horizontally COLUMNS
  1001.      This function makes the selected window COLUMNS wider.  It could
  1002.      be defined as follows:
  1003.  
  1004.           (defun enlarge-window-horizontally (columns)
  1005.             (enlarge-window columns t))
  1006.  
  1007.  - Command: shrink-window SIZE &optional HORIZONTAL
  1008.      This function is like `enlarge-window' but negates the argument
  1009.      SIZE, making the selected window smaller by giving lines (or
  1010.      columns) to the other windows.  If the window shrinks below
  1011.      `window-min-height' or `window-min-width', then it disappears.
  1012.  
  1013.      If SIZE is negative, the window is enlarged by -SIZE lines or
  1014.      columns.
  1015.  
  1016.  - Command: shrink-window-horizontally COLUMNS
  1017.      This function makes the selected window COLUMNS narrower.  It
  1018.      could be defined as follows:
  1019.  
  1020.           (defun shrink-window-horizontally (columns)
  1021.             (shrink-window columns t))
  1022.  
  1023.    The following two variables constrain the window-size-changing
  1024. functions to a minimum height and width.
  1025.  
  1026.  - User Option: window-min-height
  1027.      The value of this variable determines how short a window may become
  1028.      before it is automatically deleted.  Making a window smaller than
  1029.      `window-min-height' automatically deletes it, and no window may be
  1030.      created shorter than this.  The absolute minimum height is two
  1031.      (allowing one line for the mode line, and one line for the buffer
  1032.      display).  Actions that change window sizes reset this variable to
  1033.      two if it is less than two.  The default value is 4.
  1034.  
  1035.  - User Option: window-min-width
  1036.      The value of this variable determines how narrow a window may
  1037.      become before it automatically deleted.  Making a window smaller
  1038.      than `window-min-width' automatically deletes it, and no window
  1039.      may be created narrower than this.  The absolute minimum width is
  1040.      one; any value below that is ignored.  The default value is 10.
  1041.  
  1042.  - Variable: window-size-change-functions
  1043.      This variable holds a list of functions to be called if the size
  1044.      of any window changes for any reason.  The functions are called
  1045.      just once per redisplay, and just once for each frame on which
  1046.      size changes have occurred.
  1047.  
  1048.      Each function receives the frame as its sole argument.  There is no
  1049.      direct way to find out which windows changed size, or precisely
  1050.      how; however, if your size-change function keeps track, after each
  1051.      change, of the windows that interest you, you can figure out what
  1052.      has changed by comparing the old size data with the new.
  1053.  
  1054.      Creating or deleting windows counts as a size change, and therefore
  1055.      causes these functions to be called.  Changing the frame size also
  1056.      counts, because it changes the sizes of the existing windows.
  1057.  
  1058.      It is not a good idea to use `save-window-excursion' in these
  1059.      functions, because that always counts as a size change, and it
  1060.      would cause these functions to be called over and over.  In most
  1061.      cases, `save-selected-window' is what you need here.
  1062.  
  1063. 
  1064. File: lispref.info,  Node: Window Configurations,  Prev: Resizing Windows,  Up: Windows
  1065.  
  1066. Window Configurations
  1067. =====================
  1068.  
  1069.    A "window configuration" records the entire layout of a frame--all
  1070. windows, their sizes, which buffers they contain, what part of each
  1071. buffer is displayed, and the values of point and the mark.  You can
  1072. bring back an entire previous layout by restoring a window
  1073. configuration previously saved.
  1074.  
  1075.  - Function: current-window-configuration
  1076.      This function returns a new object representing XEmacs's current
  1077.      window configuration, namely the number of windows, their sizes
  1078.      and current buffers, which window is the selected window, and for
  1079.      each window the displayed buffer, the display-start position, and
  1080.      the positions of point and the mark.  An exception is made for
  1081.      point in the current buffer, whose value is not saved.
  1082.  
  1083.  - Function: set-window-configuration CONFIGURATION
  1084.      This function restores the configuration of XEmacs's windows and
  1085.      buffers to the state specified by CONFIGURATION.  The argument
  1086.      CONFIGURATION must be a value that was previously returned by
  1087.      `current-window-configuration'.
  1088.  
  1089.      This function always counts as a window size change and triggers
  1090.      execution of the `window-size-change-functions'.  (It doesn't know
  1091.      how to tell whether the new configuration actually differs from
  1092.      the old one.)
  1093.  
  1094.      Here is a way of using this function to get the same effect as
  1095.      `save-window-excursion':
  1096.  
  1097.           (let ((config (current-window-configuration)))
  1098.             (unwind-protect
  1099.                 (progn (split-window-vertically nil)
  1100.                        ...)
  1101.               (set-window-configuration config)))
  1102.  
  1103.  - Special Form: save-window-excursion FORMS...
  1104.      This special form records the window configuration, executes FORMS
  1105.      in sequence, then restores the earlier window configuration.  The
  1106.      window configuration includes the value of point and the portion
  1107.      of the buffer that is visible.  It also includes the choice of
  1108.      selected window.  However, it does not include the value of point
  1109.      in the current buffer; use `save-excursion' if you wish to
  1110.      preserve that.
  1111.  
  1112.      Don't use this construct when `save-selected-window' is all you
  1113.      need.
  1114.  
  1115.      Exit from `save-window-excursion' always triggers execution of the
  1116.      `window-size-change-functions'.  (It doesn't know how to tell
  1117.      whether the restored configuration actually differs from the one in
  1118.      effect at the end of the FORMS.)
  1119.  
  1120.      The return value is the value of the final form in FORMS.  For
  1121.      example:
  1122.  
  1123.           (split-window)
  1124.                => #<window 25 on control.texi>
  1125.           (setq w (selected-window))
  1126.                => #<window 19 on control.texi>
  1127.           (save-window-excursion
  1128.             (delete-other-windows w)
  1129.             (switch-to-buffer "foo")
  1130.             'do-something)
  1131.                => do-something
  1132.                ;; The frame is now split again.
  1133.  
  1134.  - Function: window-configuration-p OBJECT
  1135.      This function returns `t' if OBJECT is a window configuration.
  1136.  
  1137.    Primitives to look inside of window configurations would make sense,
  1138. but none are implemented.  It is not clear they are useful enough to be
  1139. worth implementing.
  1140.  
  1141. 
  1142. File: lispref.info,  Node: Frames,  Next: Devices,  Prev: Windows,  Up: Top
  1143.  
  1144. Frames
  1145. ******
  1146.  
  1147.    A FRAME is a rectangle on the screen that contains one or more Emacs
  1148. windows.  A frame initially contains a single main window (plus perhaps
  1149. a minibuffer window), which you can subdivide vertically or
  1150. horizontally into smaller windows.
  1151.  
  1152.    When XEmacs runs on a text-only terminal, it starts with one "TTY
  1153. frame".  If you create additional ones, XEmacs displays one and only
  1154. one at any given time--on the terminal screen, of course.
  1155.  
  1156.    When XEmacs communicates directly with an X server, it does not have
  1157. a TTY frame; instead, it starts with a single "X window frame".  It can
  1158. display multiple X window frames at the same time, each in its own X
  1159. window.
  1160.  
  1161.  - Function: framep OBJECT
  1162.      This predicate returns `t' if OBJECT is a frame, and `nil'
  1163.      otherwise.
  1164.  
  1165. * Menu:
  1166.  
  1167. * Creating Frames::        Creating additional frames.
  1168. * Frame Parameters::        Controlling frame size, position, font, etc.
  1169. * Frame Titles::                Automatic updating of frame titles.
  1170. * Deleting Frames::        Frames last until explicitly deleted.
  1171. * Finding All Frames::        How to examine all existing frames.
  1172. * Frames and Windows::        A frame contains windows;
  1173.                   display of text always works through windows.
  1174. * Minibuffers and Frames::    How a frame finds the minibuffer to use.
  1175. * Input Focus::            Specifying the selected frame.
  1176. * Visibility of Frames::    Frames may be visible or invisible, or icons.
  1177. * Raising and Lowering::    Raising a frame makes it hide other X windows;
  1178.                   lowering it makes the others hide them.
  1179. * Frame Hooks::                 Hooks for customizing frame behavior.
  1180.  
  1181.    *Note Display::, for related information.
  1182.  
  1183.